home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995…tember: Reference Library / Dev.CD Sep 95 RL / Dev.CD Sep 95 RL.toast / mac / Technical Documentation / develop / develop Issue 23 code / Multipane Dialogs Code / LDEF / Icons.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-01-05  |  8.3 KB  |  229 lines  |  [TEXT/MMCC]

  1. /*
  2.     File:        Icons.h
  3.  
  4.     Copyright:    © 1984-1993 by Apple Computer, Inc., all rights reserved.
  5.  
  6.     WARNING
  7.     This file was auto generated by the interfacer tool. Modifications
  8.     must be made to the master file.
  9.  
  10. */
  11.  
  12. #ifndef __ICONS__
  13. #define __ICONS__
  14.  
  15. enum  {
  16. /* The following are icons for which there are both icon suites and SICNs. */
  17.     genericDocumentIconResource    = -4000,
  18.     genericStationeryIconResource = -3985,
  19.     genericEditionFileIconResource = -3989,
  20.     genericApplicationIconResource = -3996,
  21.     genericDeskAccessoryIconResource = -3991,
  22.     genericFolderIconResource    = -3999,
  23.     privateFolderIconResource    = -3994,
  24.     floppyIconResource            = -3998,
  25.     trashIconResource            = -3993,
  26. /* The following are icons for which there are SICNs only. */
  27.     desktopIconResource            = -3992,
  28.     openFolderIconResource        = -3997,
  29.     genericHardDiskIconResource    = -3995,
  30.     genericFileServerIconResource = -3972,
  31.     genericSuitcaseIconResource    = -3970,
  32.     genericMoverObjectIconResource = -3969,
  33. /* The following are icons for which there are icon suites only. */
  34.     genericPreferencesIconResource = -3971,
  35.     genericQueryDocumentIconResource = -16506,
  36.     genericExtensionIconResource = -16415,
  37.     systemFolderIconResource    = -3983,
  38.     appleMenuFolderIconResource    = -3982
  39. };
  40.  
  41. #define large1BitMask 'ICN#'
  42.  
  43. #define large4BitData 'icl4'
  44.  
  45. #define large8BitData 'icl8'
  46.  
  47. #define small1BitMask 'ics#'
  48.  
  49. #define small4BitData 'ics4'
  50.  
  51. #define small8BitData 'ics8'
  52.  
  53. #define mini1BitMask 'icm#'
  54.  
  55. #define mini4BitData 'icm4'
  56.  
  57. #define mini8BitData 'icm8'
  58.  
  59. enum  {
  60.     startupFolderIconResource    = -3981,
  61.     ownedFolderIconResource        = -3980,
  62.     dropFolderIconResource        = -3979,
  63.     sharedFolderIconResource    = -3978,
  64.     mountedFolderIconResource    = -3977,
  65.     controlPanelFolderIconResource = -3976,
  66.     printMonitorFolderIconResource = -3975,
  67.     preferencesFolderIconResource = -3974,
  68.     extensionsFolderIconResource = -3973,
  69.     fontsFolderIconResource        = -3968,
  70.     fullTrashIconResource        = -3984
  71. };
  72.  
  73.  
  74. /*  alignment type values  */
  75.  
  76. enum  {
  77.     atNone                        = 0x0,
  78.     atVerticalCenter            = 0x1,
  79.     atTop                        = 0x2,
  80.     atBottom                    = 0x3,
  81.     atHorizontalCenter            = 0x4,
  82.     atAbsoluteCenter            = (atVerticalCenter|atHorizontalCenter),
  83.     atCenterTop                    = (atTop|atHorizontalCenter),
  84.     atCenterBottom                = (atBottom|atHorizontalCenter),
  85.     atLeft                        = 0x8,
  86.     atCenterLeft                = (atVerticalCenter|atLeft),
  87.     atTopLeft                    = (atTop|atLeft),
  88.     atBottomLeft                = (atBottom|atLeft),
  89.     atRight                        = 0xC,
  90.     atCenterRight                = (atVerticalCenter|atRight),
  91.     atTopRight                    = (atTop|atRight),
  92.     atBottomRight                = (atBottom|atRight)
  93. };
  94.  
  95. typedef short IconAlignmentType;
  96.  
  97.  
  98. /*  transform type values  */
  99.  
  100. enum  {
  101.     ttNone                        = 0x0,
  102.     ttDisabled                    = 0x1,
  103.     ttOffline                    = 0x2,
  104.     ttOpen                        = 0x3,
  105.     ttLabel1                    = 0x0100,
  106.     ttLabel2                    = 0x0200,
  107.     ttLabel3                    = 0x0300,
  108.     ttLabel4                    = 0x0400,
  109.     ttLabel5                    = 0x0500,
  110.     ttLabel6                    = 0x0600,
  111.     ttLabel7                    = 0x0700,
  112.     ttSelected                    = 0x4000,
  113.     ttSelectedDisabled            = (ttSelected|ttDisabled),
  114.     ttSelectedOffline            = (ttSelected|ttOffline),
  115.     ttSelectedOpen                = (ttSelected|ttOpen)
  116. };
  117.  
  118. typedef short IconTransformType;
  119.  
  120.  
  121. /*  Selector mask values  */
  122.  
  123. enum  {
  124.     svLarge1Bit                    = 0x00000001,
  125.     svLarge4Bit                    = 0x00000002,
  126.     svLarge8Bit                    = 0x00000004,
  127.     svSmall1Bit                    = 0x00000100,
  128.     svSmall4Bit                    = 0x00000200,
  129.     svSmall8Bit                    = 0x00000400,
  130.     svMini1Bit                    = 0x00010000,
  131.     svMini4Bit                    = 0x00020000,
  132.     svMini8Bit                    = 0x00040000,
  133.     svAllLargeData                = 0x000000ff,
  134.     svAllSmallData                = 0x0000ff00,
  135.     svAllMiniData                = 0x00ff0000,
  136.     svAll1BitData                = (svLarge1Bit|svSmall1Bit|svMini1Bit),
  137.     svAll4BitData                = (svLarge4Bit|svSmall4Bit|svMini4Bit),
  138.     svAll8BitData                = (svLarge8Bit|svSmall8Bit|svMini8Bit),
  139.     svAllAvailableData            = (long)0xffffffff
  140. };
  141.  
  142. typedef unsigned long IconSelectorValue;
  143.  
  144. typedef pascal OSErr (*IconActionProcPtr)(ResType theType, Handle *theIcon, void *yourDataPtr);
  145.  
  146. typedef IconActionProcPtr IconActionUPP;
  147.  
  148. #define CallIconActionProc(userRoutine, theType, theIcon, yourDataPtr)        \
  149.         (*(userRoutine))((theType), (theIcon), (yourDataPtr))
  150. #define NewIconActionProc(userRoutine)        \
  151.         (IconActionUPP)(userRoutine)
  152.  
  153. typedef IconActionProcPtr IconAction;
  154.  
  155. typedef pascal Handle (*IconGetterProcPtr)(ResType theType, void *yourDataPtr);
  156.  
  157. typedef IconGetterProcPtr IconGetterUPP;
  158.  
  159. #define CallIconGetterProc(userRoutine, theType, yourDataPtr)        \
  160.         (*(userRoutine))((theType), (yourDataPtr))
  161. #define NewIconGetterProc(userRoutine)        \
  162.         (IconGetterUPP)(userRoutine)
  163.  
  164. typedef IconGetterProcPtr IconGetter;
  165.  
  166. extern pascal OSErr PlotIconID(const Rect *theRect, IconAlignmentType align, IconTransformType transform, short theResID)
  167.  = {0x303C, 0x0500, 0xABC9};
  168. extern pascal OSErr NewIconSuite(Handle *theIconSuite)
  169.  = {0x303C, 0x0207, 0xABC9};
  170. extern pascal OSErr AddIconToSuite(Handle theIconData, Handle theSuite, ResType theType)
  171.  = {0x303C, 0x0608, 0xABC9};
  172. extern pascal OSErr GetIconFromSuite(Handle *theIconData, Handle theSuite, ResType theType)
  173.  = {0x303C, 0x0609, 0xABC9};
  174. extern pascal OSErr ForEachIconDo(Handle theSuite, IconSelectorValue selector, IconActionUPP action, void *yourDataPtr)
  175.  = {0x303C, 0x080A, 0xABC9};
  176. extern pascal OSErr GetIconSuite(Handle *theIconSuite, short theResID, IconSelectorValue selector)
  177.  = {0x303C, 0x0501, 0xABC9};
  178. extern pascal OSErr DisposeIconSuite(Handle theIconSuite, Boolean disposeData)
  179.  = {0x303C, 0x0302, 0xABC9};
  180. extern pascal OSErr PlotIconSuite(const Rect *theRect, IconAlignmentType align, IconTransformType transform, Handle theIconSuite)
  181.  = {0x303C, 0x0603, 0xABC9};
  182. extern pascal OSErr MakeIconCache(Handle *theHandle, IconGetterUPP makeIcon, void *yourDataPtr)
  183.  = {0x303C, 0x0604, 0xABC9};
  184. extern pascal OSErr LoadIconCache(const Rect *theRect, IconAlignmentType align, IconTransformType transform, Handle theIconCache)
  185.  = {0x303C, 0x0606, 0xABC9};
  186. extern pascal OSErr PlotIconMethod(const Rect *theRect, IconAlignmentType align, IconTransformType transform, IconGetterUPP theMethod, void *yourDataPtr)
  187.  = {0x303C, 0x0805, 0xABC9};
  188. extern pascal OSErr GetLabel(short labelNumber, RGBColor *labelColor, Str255 labelString)
  189.  = {0x303C, 0x050B, 0xABC9};
  190. extern pascal Boolean PtInIconID(Point testPt, const Rect *iconRect, IconAlignmentType align, short iconID)
  191.  = {0x303C, 0x060D, 0xABC9};
  192. extern pascal Boolean PtInIconSuite(Point testPt, const Rect *iconRect, IconAlignmentType align, Handle theIconSuite)
  193.  = {0x303C, 0x070E, 0xABC9};
  194. extern pascal Boolean PtInIconMethod(Point testPt, const Rect *iconRect, IconAlignmentType align, IconGetterUPP theMethod, void *yourDataPtr)
  195.  = {0x303C, 0x090F, 0xABC9};
  196. extern pascal Boolean RectInIconID(const Rect *testRect, const Rect *iconRect, IconAlignmentType align, short iconID)
  197.  = {0x303C, 0x0610, 0xABC9};
  198. extern pascal Boolean RectInIconSuite(const Rect *testRect, const Rect *iconRect, IconAlignmentType align, Handle theIconSuite)
  199.  = {0x303C, 0x0711, 0xABC9};
  200. extern pascal Boolean RectInIconMethod(const Rect *testRect, const Rect *iconRect, IconAlignmentType align, IconGetterUPP theMethod, void *yourDataPtr)
  201.  = {0x303C, 0x0912, 0xABC9};
  202. extern pascal OSErr IconIDToRgn(RgnHandle theRgn, const Rect *iconRect, IconAlignmentType align, short iconID)
  203.  = {0x303C, 0x0613, 0xABC9};
  204. extern pascal OSErr IconSuiteToRgn(RgnHandle theRgn, const Rect *iconRect, IconAlignmentType align, Handle theIconSuite)
  205.  = {0x303C, 0x0714, 0xABC9};
  206. extern pascal OSErr IconMethodToRgn(RgnHandle theRgn, const Rect *iconRect, IconAlignmentType align, IconGetterUPP theMethod, void *yourDataPtr)
  207.  = {0x303C, 0x0915, 0xABC9};
  208. extern pascal OSErr SetSuiteLabel(Handle theSuite, short theLabel)
  209.  = {0x303C, 0x0316, 0xABC9};
  210. extern pascal short GetSuiteLabel(Handle theSuite)
  211.  = {0x303C, 0x0217, 0xABC9};
  212. extern pascal OSErr GetIconCacheData(Handle theCache, void **theData)
  213.  = {0x303C, 0x0419, 0xABC9};
  214. extern pascal OSErr SetIconCacheData(Handle theCache, void *theData)
  215.  = {0x303C, 0x041A, 0xABC9};
  216. extern pascal OSErr GetIconCacheProc(Handle theCache, IconGetterUPP *theProc)
  217.  = {0x303C, 0x041B, 0xABC9};
  218. extern pascal OSErr SetIconCacheProc(Handle theCache, IconGetterUPP theProc)
  219.  = {0x303C, 0x041C, 0xABC9};
  220. extern pascal OSErr PlotIconHandle(const Rect *theRect, IconAlignmentType align, IconTransformType transform, Handle theIcon)
  221.  = {0x303C, 0x061D, 0xABC9};
  222. extern pascal OSErr PlotSICNHandle(const Rect *theRect, IconAlignmentType align, IconTransformType transform, Handle theSICN)
  223.  = {0x303C, 0x061E, 0xABC9};
  224. extern pascal OSErr PlotCIconHandle(const Rect *theRect, IconAlignmentType align, IconTransformType transform, CIconHandle theCIcon)
  225.  = {0x303C, 0x061F, 0xABC9};
  226.  
  227. #endif
  228.  
  229.